<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>

<link rel="stylesheet" type="text/css"
	href="style/jquery-ui-1.8.8.custom.css"></link>
<link rel="stylesheet" type="text/css"
	href="style/reset-fonts-grids.css"></link>
<link rel="stylesheet" type="text/css"
	href="style/tmpl.css"></link>

<script type="text/javascript" src="js/jquery-1.4.4.min.js"></script>
<script type="text/javascript" src="js/jquery-ui-1.8.8.custom.min.js"></script>
<script type="text/javascript" src="js/yahoo-min.js"></script>
<script type="text/javascript" src="js/json.js"></script>
<script type="text/javascript" src="js/jquery.template-0.3.js"></script>

<script type="text/javascript">
var templateDoc = null;
var xmlObj = null;

function setContent(c) {
	c = unescape(String(c).replace(/\+/g, " "));
	$('#instance').html(c);
}

function getData() {
	setEditorContents("getdata");
}

function initUI() {
}

function setFieldValue(elem) {
	try {
		var id = elem.id;
		var val = $(elem).val();
		var status = setFieldInJava(id, val);
		markError(elem.id, !status);
	} catch(e) {
		alert(e.message);
	}
}

function addListItem(el) {
	window.setTimeout(function() {
		addListItemJava(el.id);
	}, 0);
}

function delListItem(el) {
	window.setTimeout(function() {
		delListItemJava(el.id);
	}, 0);
}

function markError(id, errorFlag) {
	var $el = $('#' + id);
	if (errorFlag) {
		$el.addClass('error')
	} else {
		$el.removeClass('error');
	}
}
</script>
</head>
<body>
	<div id="instance">
	</div>
</body>
</html>
